﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using DAL;
using Models;

namespace BLL
{
    public class PJSearchManager
    {
        private PJSearchService objPJSearchService = new PJSearchService();
        public List<ProjectMain> GetMain(PJSearch PJSearch)
        {
            return objPJSearchService.GetMain(PJSearch);
        }
        public List<ProjectMain> GetMain(string mold, string name, string createDate1, string createDate2, string[] pjTypes, string[] moldTypes, string[] labelTypes)
        {
            return objPJSearchService.GetMain(mold, name, createDate1, createDate2, pjTypes, moldTypes, labelTypes);
        }
        public int GetId(string pjId)
        {
            return objPJSearchService.GetId(pjId);
        }
        public List<PJLog> GetLog(string pjId)
        {
            return objPJSearchService.GetLog(pjId);
        }
        public ProjectMain GetMain(string pjId)
        {
            return objPJSearchService.GetMain(pjId);
        }
       
        /// <summary>
        /// 根据模具号查找节点
        /// </summary>
        /// <param name="pjId"></param>
        /// <returns></returns>
        public List<PJNode> GetNode(string pjId)
        {
            return objPJSearchService.GetNode(pjId);
        }
        /// <summary>
        /// 节点状态查询
        /// </summary>
        /// <param name="PJSearch"></param>
        /// <returns></returns>
        public List<PJNodeShow> GetNode(PJSearch PJSearch)
        {
            return objPJSearchService.GetNode(PJSearch);
        }
        public List<PJNodeShow> GetNode(string mold, string name, string createDate1, string createDate2, string[] pjTypes, string[] moldTypes, string[] labelTypes)
        {
            return objPJSearchService.GetNode(mold, name, createDate1, createDate2, pjTypes, moldTypes, labelTypes);
        }
        public List<PJOrderStart> GetOrderStart(string matnr, string person, string mold)
        {
            return objPJSearchService.GetOrderStart(matnr, person, mold);
        }
        public List<PJSampleOut> GetSampleOut(string matnr)
        {
            return objPJSearchService.GetSampleOut(matnr);
        }
        public List<PJNode> GetNode(string pjId, string displayName, DateTime date1, DateTime date2)
        {
            return objPJSearchService.GetNode(pjId, displayName, date1, date2);
        }
        public List<PJLog> GetLog(string mold, string name, string createDate1, string createDate2, string[] degrees, string[] departments, string[] labelTypes)
        {
            return objPJSearchService.GetLog(mold, name, createDate1, createDate2, degrees, departments, labelTypes);
        }
        public int UpdatePJMainsPs(string pjId, string ps)
        {
            return objPJSearchService.UpdatePJMainsPs(pjId, ps);
        }
        public int UpdatePJNodesPs(string pjId, string ps)
        {
            return objPJSearchService.UpdatePJNodesPs(pjId, ps);
        }
        public int UpdatePJLogsPs(string id, string ps2)
        {
            return objPJSearchService.UpdatePJLogsPs(id, ps2);
        }
        public string SearchPJMainsPs(string pjId)
        {
            return objPJSearchService.SearchPJMainsPs(pjId);
        }
        public string SearchPJNodesPs(string pjId)
        {
            return objPJSearchService.SearchPJNodesPs(pjId);
        }
        public string SearchPJLogsPs(string id)
        {
            return objPJSearchService.SearchPJLogsPs(id);
        }
    }
}
